# KALE - Kirby's Adventure Level Editor

version 0.92

Introduction - The main window - Editing tiles - Editing exits - The properties window Editing map clear data - Editing tilesets - Editing palettes Credits - What's new - Remarks - Contact

# Introduction

KALE is a level editor for Kirby's Adventure.

KALE supports editing almost every part of the game's level data, including sprite and exit locations, tilesets, palettes, and overworld progression. The editor supports all North American, European, and Japanese ROMs.

Source code is available on GitHub, and is distributed under the MIT license.

(top)

# The main window

The main window is where all level editing takes place. When you load a ROM, level data is shown tile-for-tile exactly as it appears in game, with sprites and exits represented by red and blue squares, respectively. Each room is divided into screens (16 tiles wide by 12 tiles tall), which are numbered in the upper left corner. (These screen numbers are used to determine exit destinations; see the exit editing section for more info.)

Hovering over a tile with the mouse will display its tile number and behavior (in hexadecimal) on the window's status bar.

The View menu can be used to control some properties of how the current room is displayed, including scaling (double size), screen boundaries, and blending of destroyable tiles (such as bombs or star blocks) with the tile they leave behind.

When selecting tiles is enabled, clicking and dragging will select a tile or range of tiles, which you can then edit by double-clicking, selecting the "Edit Tiles" option on the Edit menu or toolbar, or pressing the "E" key. This will bring up the tile edit window, allowing you to replace the selected tiles. To deselect tiles, right-click anywhere within the level view.

Otherwise, clicking and dragging will select either sprites or exits, which can be moved around and deleted individually or in groups. Double-clicking an individual sprite or exit will allow you to edit it (see editing exits for more information on the latter), and right-clicking will insert a new one at the current location.

(Note: Currently, moving or editing sprites and exits doesn't result in a "dirty" editing state, and so changes to either one will be saved automatically when changing levels if no other changes were made. Actions involving sprites or exits currently aren't added to the undo/redo stack; this will be changed eventually.)

To change rooms, click the "Select Room..." option on the Level menu or the toolbar. Use the "previous/next room" options to move back/forward one room at a time, or hold Ctrl and use the left/right arrow keys.

The "Save Room" option in the Level menu will save all outstanding changes to the current room; otherwise, you will be prompted to do so when changing rooms or saving the ROM.

(top)

# Editing tiles

This is the window which appears when you double-click a selection of tiles or select the "Edit Tiles" menu option. All 256 tiles in the current tile set are displayed here, and mousing over a tile will display its behavior underneath. Clicking a tile will change all of the currently selected tiles in the room.

To select which tiles and graphics a room uses, open the properties window.

(top)

# Editing exits

This is the window which appears when you double-click an exit.

Some general information about editing exits:

- The destination of an exit is specified as a screen number and coordinates within that screen. If the dimensions of a level are changed, exits pointing to that level may need to be updated to point to the correct screen numbers.
- In order to work, an exit must be placed on a tile with behavior 0x28 (i.e. any door tile)
- Due to limited ROM space, Kirby's Adventure already has the maximum number of possible exits. In order to add new exits to a room, others will have to be removed, either from the current room or from another (there are several debug rooms and other unused rooms which exits can be stolen from if desired).
- When using a warp star, there must be an exit within the level which determines where the warp star actually leads to. Ideally it should be the only exit in the level, or else the warp star may not go to the intended destination. (Currently there is no way to define custom warp star animations, as the game uses hardcoded animations based on the current world and stage number.)

Additionally, when exit type 1F ("next level") is selected, some additional information can be entered about the boss level that the door leads to prior to the next level becoming available. This info is only valid for rooms 000 through 007 (i.e. overworlds and the debug hub).

(top)

# The properties window

The properties window allows you to customize some details of the current room.

The width and height boxes control the dimensions of the room, measured in whole screens. The total area of a room (width times height) cannot exceed 16 screens.

The "don't return to this room after losing a life" setting determines whether the player will continue in the current room after losing a life, or be sent back to their previous location. This is commonly enabled for miniboss encounters.

The tile graphics combo box allows you to select 8x8 tile graphics from various preset combinations of CHR ROM banks (along with bank 00, which contains various common graphics such as star blocks, powerups, and doors, and is always present). The last bank value of each combination represents a range of four banks which can be cycled through by enabling animation (note that not all of these banks are actually designed to be animated, and will produce strange results if attempted). The animation speed slider allows you to control this cycle interval in frames (1/60 sec. for US/JP, 1/50 sec. for EU).

The tileset box determines how the selected 8x8 tile graphics are combined into 16x16 tiles, as well as how they behave (these can be edited using the tileset editor).

The sprite box determines the graphics used for the current room's sprites. Sprites actually use two consecutive CHR ROM banks (so for example, selecting sprite bank 9A will use both 9A and 9B). The "sprites" tab on the right side of the window lets you view the currently selected sprite graphics and palette; this is useful for being able to determine which enemy types are currently usable in the room.

Both tile and sprite palettes can be modified using the palette editor.

## Extended properties

This tab allows you to define some additional properties which are not part of the original room data format. For these options to be available, you must first apply a small patch to your ROM by selecting "Apply Extra Room Data Patch..." from the Extra menu. This allows some additional info, which was originally restricted to specific rooms, to be used anywhere.

The properties currently available on this tab are:

- Wind, how fast it blows and in which direction
- A position to lock the screen at when facing a miniboss, or a position to generate a door when a miniboss is defeated
- The number of minibosses that appear

Note that when generating a door, the "open" door should be placed in the room itself, and the two tiles which initially cover it up are specified in this tab.

The extra room data patch has the additional benefit of allowing star switches (sprites 0xFE and 0xFF) to be placed anywhere in a room of any size, removing a limitation of the original game.

(top)

# Editing map clear data

This window is available from the Level menu or the toolbar, and allows you to control which parts of overworlds are revealed when a level is cleared or a switch is pressed.

Since this info is limited to the overworld, the window is only accessible when editing rooms 000 through 006. Also, similarly to exits, the number of total regions defined by this data is limited.

The currently selected regions can be previewed by looking at the main window; the overworld will be covered up just like in game, except for the current regions.

(top)

# Editing tilesets

The tileset editor allows you to assemble 16x16 tiles and select their behavior and color information. The "display properties" box works the same way as the corresponding controls on the room properties window; their values default to the ones used by the current room.

The tabs on the right switch between the tileset's 16x16 tiles and the 8x8 tiles which make up the current "tile graphics" setting. Clicking on a 16x16 tile will allow you to edit it and view your changes in real time.

The "subtract this # when tiles are broken" box determines the number (in hexadecimal) that is subtracted when a breakable block (such as a bomb or a star block) is destroyed. For example, if tile F8 is a star block and this value is 08, then inhaling the star block will replace it with a tile of type F0 (ideally some kind of background tile). This value is only valid for tilesets 00 through 1E; tilesets 1F and above are not intended for ingame use, but can be used as such; if you do, don't define any breakable blocks or the results in game will be unpredictable!

(top)

# Editing palettes

Finally, the palette editor allows you to edit both background tile and sprite palettes. Once again, this window's settings default to the palettes used by the current room.

To edit a color, double-click it and enter a valid NES color number (in hexadecimal). For reference, here is a chart of valid colors (top row: 00-0F, bottom row: 30-3F):

(top)

# Credits

The author would like to extend well-earned salami sandwiches to each of the following individuals and groups:

- borokobo / PureSabe for creating DreamTool, the Kirby's Adventure hacking tool (in Japanese) which partially inspired the creation of this one (and which helped me verify some of my own information)
- The Cutting Room Floor and #tcrf for moral support and once again giving me inspiration to poke around this game
- DarkMatt for testing
- J^P for even more testing
- Kapow for posting lots of info on Data Crystal and helping me corroborate some of my own findings (some of which I found before realizing said Data Crystal page even existed and rightly felt like an idiot for afterwards)
- Mark James (famfamfam) for the Silk Icons set, used for menu and toolbar graphics
- Raccoon Sam for build assistance and testing on OS X
- Reimu for extensive testing, feedback, graphic design, and lots of poking around the game's insides
- Everyone else who has downloaded and supported the development of this program in any way

(top)

# What's new

See the full changelog for a complete version history.

(top)

# Remarks

This program has now been in on-and-off development for at least a whole year now. The KALE repo on GitHub was created on New Year's Day 2014, consisting of a single experimental Lua script for FCEUX, and slowly grew from there. I didn't do as much with it in the later half of the year, due mostly to gaining a full-time job as a C++/Qt developer and other real-life nonsense, but I'm happy with the editor nonetheless.

Now I'm writing this in the very first minutes of New Year's Eve, 364 days after the first commit, and getting ready to push what might be the final ROM hacking utility release of the year. It's been a bit exciting to see a few people actually putting it to use in that time; maybe Kirby hacking will finally become a Big Thing one of these days.

Some minor things are still indefinitely unfinished due mostly to lack of free time, but I hope you still find this pet project useful. Happy new year.

(top)

# Contact

If you want to yell at me about something, here's how you can:

Email:
d@revenant1.net

IRC:
"devin" on irc.badnik.net
"Revenant`" on OFTC, SynIRC, DALnet, and EsperNet

Forums:
http://jul.rustedlogic.net/profile.php?id=504
http://www.romhacking.net/forum/index.php?action=profile;u=10455

(top)

copyright 2014-2015 Devin "Revenant" Acker - "life is but a dream"